Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add docs for publish signal #163

Merged
merged 1 commit into from
Oct 21, 2019

Conversation

jonathan-s
Copy link
Contributor

Docs as promised in #159

@Aiky30
Copy link
Collaborator

Aiky30 commented Oct 14, 2019

Can we add an example usage in the docs like in versioning? Makes it much easier for anyone using the signal: https://github.com/divio/djangocms-versioning/blob/master/docs/signals.rst

@jonathan-s
Copy link
Contributor Author

@Aiky30 I've added an example as well.

docs/signals.rst Outdated


@receiver(published)
def do_something_unpublish_event(*args, **kwargs):
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be "publishing" rather than "unpublishing"

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll change this to do_something_on_published_event

Related to #166, do we want to have a separate event trigger for unpublished? For a user of the library it would be clearer, technically you would be able to achieve the same by checking whether the workflow is is_unpublishing or not.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Personally I'd go for separate signals as they are separate concerns. We should stay consistent with Versioning.

@jonathan-s
Copy link
Contributor Author

jonathan-s commented Oct 21, 2019 via email

@Aiky30
Copy link
Collaborator

Aiky30 commented Oct 21, 2019

Merging with failures due to the fact that this is documentation and contains no code changes. CircleCI have changed their pricing plan and we are using features that are no longer part of the open source offering.

@Aiky30 Aiky30 merged commit 1f64ce9 into django-cms:release/1.0.x Oct 21, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants